package com.wenzhi.java_join_kotlin.controller;

import com.wenzhi.java_join_kotlin.model.KotlinStudent;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/student")
public class StudentController {
    @GetMapping("/java")
    public String sayJava() {
        KotlinStudent java = new KotlinStudent("java");
        // return "Java";
        return java.getName();
    }
}
